<?php

include('../config.php');

$log = new Logging();

$log->lfile('../logs/expected_utilization_rate_' . date('Y_m_d') . '.log');
$log->lwrite('Start');

$task_obj = new task_obj();

$filter = array(
    'type' => 1
);
$tasks = $task_obj->getListOfTasks($filter, array(), '', 'taskId');

if (!empty($tasks)){
    foreach ($tasks as $key => $task) {
        $task_obj->updateTaskRate($task['taskId']);
    }
}

$log->lwrite('Stop');
$log->lwrite('------------------------------------------');

$log->lclose();
?>
